<template>
  <div>
    <!-- <div>
          {{ arr }} <button @click="change">修改</button>
      </div> -->

    <el-table :data="arr" style="width: 100%">
      <el-table-column prop="date" label="Date" width="180" />
      <el-table-column prop="name" label="Name" width="180" />
      <el-table-column prop="address" label="Address" />
    </el-table>
  </div>
</template>

<script>
import { toRefs } from "vue";
import { useTable } from '../hooks/table'
export default {
  setup() {
    const { tableData } = useTable("/one");
    return {
        ...toRefs(tableData)
    };
  },

  //   setup() {
  //     let arr = reactive([1, 2, 3]);
  //     //   console.log(arr)
  //     const change = () => {
  //       //   arr[0] = 44
  //       arr = [444, 2, 4];
  //       console.log("change");
  //     };
  //     return {
  //       arr,
  //       change,
  //     };
  //   },
};
</script>

<style>
</style>